home *** CD-ROM | disk | FTP | other *** search
/ A.C.E. 2 / ACE CD 2.iso / FILES / UTILS / HSBASIC2.DMS / in.adf / HB2Examples2.0.Lha / Examples / NLMenu / ReadMe < prev   
Encoding:
Text File  |  1994-05-05  |  2.8 KB  |  57 lines

  1. NLMenu.bas - Show use of NewLook menus using Intuition, GadTools and Locale
  2. ===========================================================================
  3.  
  4. Derived from example (c) Copyright 1992 Commodore-Amiga, Inc.
  5.  
  6. This is a translation of the Commodore RKM example "GadTools Menus Example",
  7. taken from the Libraries RKM p.372. The example has been enhanced to use the
  8. Workbench 3 "New-Look" imagery, and includes a substantial amount of code
  9. to aid in constructing the input array (since BASIC does not support static
  10. initialisation as per C). All strings used by the program are obtained via
  11. the current locale (assuming locale.library is present).
  12.  
  13. The example opens a window on the default public screen (note that a BASIC
  14. window cannot be used as the WA_NewLookMenus tag is not passed by BASIC for
  15. its own windows), the ASL font requester is used to obtain a font for
  16. rendering the menu in (the default is the system default screen text). If a
  17. custom font is selected BOOPSI images for the Amiga key and check mark are
  18. created (these will only succeed for WB3.0 and later). The window is then
  19. opened and messages swallowed until the window is closed.
  20.  
  21. The include file BLib/GadToolsMenus.bas provides routines for building the
  22. members of the array passed to the GadTools routines.
  23.  
  24. The example will work on versions of Workbench 2.0 or later (V36 and above)
  25.  
  26. Compiling
  27. ---------
  28. Load the NLMenu_inc.bh file and Tokenise it (Program-Tokenise), making sure
  29. you have no token file selected in the File Options (Settings-Compiler-Files).
  30. Once you have your token file, set the File Options-Token File setting to the
  31. NLMenu_inc.t file just created. Load the NLMenu.bas file, compile and run it.
  32.  
  33. In addition a number of files are automatically generated; note that these
  34. command sequences require CatComp (included in the NDUK 3.1 available from
  35. Commodore), RX (included as part of ARexx in WB2.0), the BASIC OToTagList
  36. program (in the HBASIC2:Tools drawer) and the EQUToBC.rexx script (in the
  37. HBASIC2:Rexx drawer). In addition the PIPE: device must be mounted (if its not
  38. move it from the SYS:Storage/DOSDrivers drawer to the SYS:DEVS/DOSDrivers
  39. drawer & reboot to mount it).
  40.  
  41. The files may then be generated in the following way:
  42.  
  43. NLMenu_strings.bc (IDs defining strings in a catalog)
  44. -----------------------------------------------------
  45. CatComp NLMenu_strings.cd ASMFILE PIPE:0
  46. RX EQUToBC.rexx <PIPE:0 >NLMenu_strings.bc
  47.  
  48. NLMenu_strings.bas (Code & Default strings when catalog not present)
  49. --------------------------------------------------------------------
  50. CatComp NLMenu_strings.cd OBJFILE NLMenu_strings.o
  51. OToTaglist NLMenu_strings.o NLMenu_strings.bas
  52. Delete NLMenu_strings.o
  53.  
  54. français/NLMenu.catalog (French catalog translation)
  55. ----------------------------------------------------
  56. CatComp NLMenu_strings.cd NLMenu_français.ct CATALOG Catalogs/français/NLMenu.catalog
  57.